<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="renderer" content="webkit">
    <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
    <meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no"/>
    <title>统计分析</title>
    <link rel="stylesheet" type="text/css" href="${s.base}/lib/layui/css/layui.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/css/base/index.css"/>
    <link rel="stylesheet" type="text/css" href="${s.base}/css/base/theme/theme.css"/>
</head>
<style type="text/css">

</style>
<body>
<div class="wrap-container clearfix">
    <div class="column-content-detail">
        <div class="layui-form" id="table-list">
            <form class="layui-form" method="post" action="/work/asset/exportWarranty">
                <div class="wxyy--table-title" style="text-align:left!important;">统计分析列表</div>
                <div class="tab-menu-nav clearfix">
                    <ul>
                        <li class="checked" data-id="xktot">老师巡考情况统计</li>
                        <li data-id="jktot">老师监考情况统计</li>
                        <li data-id="kstot">学生考试情况统计</li>
                    </ul>
                </div>
                <div id="xktot" style="margin-top: 10px;">
                    <div class="operation-btn-cont">
                        <button class="layui-btn layui-btn-normal layui-btn-mid" type="button" id="exportxkBtn"><i class="iconfont marr5">&#xe614;</i>导出</button>
                    </div>

                    <div class="layui-form" id="table-listxk" style="margin-top: 10px;">
                        <table id="entityListxk" lay-filter="entityList" class="cy-list-table"></table>
                    </div>

                </div>
                <div id="jktot"  style="display:none" >
                    <div class="operation-btn-cont">
                        <button class="layui-btn layui-btn-normal layui-btn-mid" type="button" id="exportjkbtn"><i class="iconfont marr5">&#xe614;</i>导出</button>
                    </div>
                    <div class="layui-form" id="table-listjk" style="margin-top: 10px;">
                        <table id="entityListjk" lay-filter="entityList" class="cy-list-table"></table>
                    </div>
                </div>
                <div id="kstot" style="margin-top: 10px; display: none;">
                    <div class="operation-btn-cont">
                        <button class="layui-btn layui-btn-normal layui-btn-mid" type="button" id="exportstuBtu"><i class="iconfont marr5">&#xe614;</i>导出</button>
                    </div>
                    <div class="layui-form" id="table-liststu" style="margin-top: 10px;">
                        <table id="entityListstu" lay-filter="entityList" class="cy-list-table"></table>
                    </div>
                </div>
            </form>
        </div>
    </div>
</div>
<!--操作-->
<script src="${s.base}/lib/layui/layui.js" type="text/javascript" charset="utf-8"></script>
<script src="${s.base}/js/common.js" type="text/javascript" charset="utf-8"></script>
<script>
    var tableIns = null;
    var tableIns1 = null;
    var tableIns2 = null;
    layui.use(['jquery', 'table', 'page', 'dialog'], function () {
        var $ = layui.jquery,
            page = layui.page,
            table = layui.table,
            dialog = layui.dialog;

        //获取分页数据
        //获取获取学生考场分配的情况

            var url = "/work/kwmanagement/kwteachersetting/getAllTeacherXkNumer";
            var cols = [
                {field: 'title', title: '序号', align: 'left', width: 80, type: 'numbers'},
                {field: 'xkName', title: '姓名', align: 'center'},
                {field: 'xkNum', title: '巡考次数', align: 'center'},
                {field: 'sortNumber', title: '排名', align: 'center'}
            ];

        tableIns = page.newInitDate("entityListxk",cols, url);

        var url1 = "/work/kwmanagement/kwteachersetting/getAllTeacherJkNumer";
        var cols1 = [
            {field: 'title', title: '序号', align: 'left', width:80,type:'numbers'},
            {field: 'jkName', title: '姓名', align: 'center'},
            {field: 'jkNum', title: '监考次数', align: 'center'},
            {field: 'sortNumber', title: '排名', align: 'center'}
        ];
        tableIns1 = page.newInitDate("entityListjk",cols1, url1);


        var url2 = "/work/kwmanagement/kwstudentmessage/getStudnetAllstatic";
        var cols2 = [
            {field: 'title', title: '序号', align: 'left', width:80,type:'numbers'},
            {field: 'name', title: '姓名', align: 'center'},
            {field: 'userNumber', title: '学号', align: 'center'},
            {field: 'attecenExamNum', title: '应考次数', align: 'center'},
            {field: 'absentceExamNum', title: '缺考次数', align: 'center'},
        ];
        tableIns2 = page.newInitDate("entityListstu",cols2, url2);

        $(".layui-table-box").css("height", $(".layui-table-box").css("height"));
         //导出巡考老师
        $("#exportxkBtn").on("click",function () {
            window.location.href = "/work/kwmanagement/kwstudentmessage/exportxkTea";
        });

        //导出监考老师
        $("#exportjkbtn").on("click",function () {
            window.location.href = "/work/kwmanagement/kwstudentmessage/exportjkTea";
        });

        //导出学生
        $("#exportstuBtu").on("click",function () {
            window.location.href = "/work/kwmanagement/kwstudentmessage/exportksStudnet";
        });

        $(".tab-menu-nav ul li").click(function(){
            $(".tab-menu-nav ul li").removeClass("checked");
            $(this).addClass("checked");
            $("#xktot").hide();
            $("#jktot").hide();
            $("#kstot").hide();
            var idname=$(this).attr("data-id");
            $("#"+idname).show();
            table.reload();

        })

    });
</script>
</body>
</html>